<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@page import="com.systop.ltbook.webapp.LtConstants, java.util.Map, java.util.List, com.systop.cms.model.Articles" %>
<%@ include file="/common/taglibs.jsp"%>
<% Map<String, Object> data = (Map<String, Object>)request.getAttribute("data"); %>
<table width="1002" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="210" valign="top">
      <%@include file="/pages/new/index_menu_left.jsp" %>
    </td>
    <td width="567" valign="top" style="padding-top: 5px;">
      <table width="550" height="200" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td>
			<script type="text/javascript">
				function lovestory(element,url,width,height,images,links,texts){
					var str = '';
					str += '<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,9,0" width="'+ width +'" height="'+ height +'">';
					str += '<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="'+url+'"><param name="quality" value="high"><param name="bgcolor" value="#ffffff">';
					str += '<param name="menu" value="false"><param name=wmode value="opaque">';
					str += '<param name="FlashVars" value="pics='+images+'&amp;links='+links+'&amp;texts='+texts+'&amp;borderwidth='+width+'&amp;borderheight='+height+'&amp;textheight=0">';
					str += '<embed src="'+url+'" wmode="opaque" FlashVars="pics='+images+'&amp;links='+links+'&amp;texts='+texts+'&amp;borderwidth='+width+'&amp;borderheight='+height+'&amp;textheight=0" menu="false" bgcolor="#ffffff" quality="high" width="'+ width +'" height="'+ height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />';
					str += '</object>';
					document.write(str);
				}
	
				imgtext1="1";
				imgLink1=escape("#");
				imgtext2="2";
				imgLink2=escape("#");
				imgtext3="3";
				imgLink3=escape("#");
				imgtext4="4";
				imgLink4=escape("#");
				imgtext5="5";
				imgLink5=escape("#");
	
				var focus_width=560;
				var focus_height=200;
				var text_height=0;
				var swf_height = focus_height+text_height;
				<% 
				  Map eliteInfo = (Map)data.get(LtConstants.ELITE_INFO);
				%>
				
				var pics='<%=eliteInfo.get("imgs")%>';
				
				var links='<%=eliteInfo.get("urls")%>';
				var texts='<%=eliteInfo.get("titles")%>';
				lovestory('story_flash','${ctx}/images/lt_new/focus.swf',focus_width,swf_height,pics,links,texts);
		  	</script>
          </td>
        </tr>
      </table>
      <table width="560" border="0" align="center" cellpadding="0" cellspacing="0" style="margin-top:10px;">
        <tr>
          <td colspan="2" style="border-bottom: 1px dotted #339900; padding:5px 0px 2px 10px;">
            <a href="#" target="_blank" style="font-size: 14px; font-weight: bold;">
              &nbsp;热门资讯&nbsp;<img src="${ctx}/images/lt_new/arrow_4.gif">
            </a>
          </td>
        </tr>
        <% 
			List<Articles> hotInfos = (List)data.get(LtConstants.HOT_INFOS);
        	int size = hotInfos.size();
        	int fstEnd = 0;
        	int senEnd = 0;
        	if (size > 6){
        		fstEnd = 6;
        		senEnd = size;
        	}else{
        		fstEnd = size;
        		senEnd = 0;
        	}
		%>
	    <tr>
	      <td width="50%" height="150" style="padding-top:10px;" valign="top">
	        <ul class="ul_style">
	          <% for(int i = 0; i < fstEnd; i++){ %>
		          <li><a href="${ctx}/ltart/view.do?model.id=<%=hotInfos.get(i).getId()%>" target="_blank"><%=hotInfos.get(i).getShortTitle()%></a></li>
	          <% } %>
	        </ul>
	      </td>
	      <td width="50%" height="150" style="padding-top:10px;" valign="top">
	        <ul class="ul_style">
	        <% 
	        	if (senEnd != 0){
	        	for(int i = 6; i < senEnd; i++){ 
	         %>
		          <li><a href="${ctx}/ltart/view.do?model.id=<%=hotInfos.get(i).getId()%>" target="_blank"><%=hotInfos.get(i).getShortTitle()%></a></li>
	         <% }} %>
	        </ul>
	      </td>
	    </tr>
      </table>
    </td>
    <td width="220" valign="top">
      <!-- 公告模块 start -->
      <table width="218" height="200" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td height="36" align="center" background="${ctx}/images/lt_new/right_bg.gif" class="greenfont">
          	<a href="${ctx}/ltcata/catalog.do?path=/gg" target="_blank" style="color: green; font-size: 14px;">最新公告</a>
          </td>
        </tr>
        <tr>
          <td height="150" background="${ctx}/images/lt_new/right_2.gif" style="padding: 5px 12px; line-height: 25px;">
            <marquee direction="up"  scrollamount="2" onmousemove="this.stop()" onmouseout="this.start()" height="150" >
              <%
              	List<Articles> notices = (List<Articles>)data.get(LtConstants.NOTICES);
             %>
             <%	for(Articles art : notices){ %>
             	·&nbsp;<a href="${ctx}/ltart/view.do?model.id=<%=art.getId()%>" target="_blank"><%=art.getShortTitle() %></a><br>
             <%}%>
            </marquee>
          </td>
        </tr>
        <tr>
          <td height="14" background="${ctx}/images/lt_new/right_3.gif"></td>
        </tr>
      </table>
      <!-- 公告模块 end -->
      
      <!-- 专题模块 start -->
      <table width="218" height="195" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td align="center" height="36" background="${ctx}/images/lt_new/right_bg.gif" class="greenfont">
          	<a href="${ctx}/ltcata/catalog.do?path=/zt" target="_blank" style="color: green; font-size: 14px;">专题专访</a></td>
        </tr>
        <tr>
          <td background="${ctx}/images/lt_new/right_2.gif" style="padding: 5px 12px; line-height: 25px;">
            <marquee direction="up"  scrollamount="2" onmousemove="this.stop()" onmouseout="this.start()" height="150" >
            <s:iterator value="#attr.data.subjects" var="subject">
            	·&nbsp;<a href="${ctx}/ltart/view.do?model.id=${subject.id}" target="_blank">${subject.shortTitle}</a>
            </s:iterator>
            </marquee>
          </td>
        </tr>
        <tr>
          <td><img src="${ctx}/images/lt_new/right_3.gif" width="218" height="14" /></td>
        </tr>
      </table>
      <!-- 专题模块 end -->
    </td>
  </tr>
</table>